#ifndef __NETFORWARD_H__
#define __NETFORWARD_H__
#include "cmap.h"
#include <stdint.h>


typedef enum NetType_e{
    NETTYPE_TCP = 0,
    NETTYPE_UDP = 1
}NET_TYPE;


/* add netforward pair:localip:port->remoteip:port */
int netforward_add_config(const char *ip, uint16_t port, const char *remoteip, uint16_t remoteport, NET_TYPE type);
int netforward_reset_config();
int netforward_get_config();

int netforward_start();
int netforward_stop();
void netforward_init();

#ifndef NDEBUG
void tst();
#endif

#endif // !__NETFORWARD_H__
